{extend name="base"/}
{block name="resources"}
<style>
    .required { margin-right: 3px; }
    .ns-check-member { position: relative; }
    .ns-check-member .layui-btn { position: absolute; top: 0; right: 1px; border-color: #e5e5e5; padding: 0 10px; border-right: 0; }

    .ns-store-company, .ns-pay-company, .ns-pay-alipay, .ns-shop-own { display: none; }

    /* 关联会员 */
    .ns-search-result { border: 1px solid; padding: 15px 30px 15px 15px; display: flex; align-items: center; position: relative;margin-top:10px; }
    .ns-search-res-img { width: 50px; height: 50px; margin-right: 5px; text-align: center; line-height: 50px; }
    .ns-search-res-img img { max-width: 100%; max-height: 100%; }
    .ns-search-res-intro p { line-height: 24px; }
    .ns-search-res-close { position: absolute; top: 5px; right: 5px; }

    .ns-card-common:first-of-type {margin-top: 0;}
    .ns-form-row {margin-top: 0;}
    .ns-check-member .layui-input:focus+.layui-btn {border-color: #4685FD;}
    .ns-store-company, .ns-pay-company{margin-top: 10px;}
    .ns-form {margin-top: 0;}
    .tree-line{padding:10px 0;background:#ededed;margin-bottom:2px;line-height: 1.8;}
    .tree-line .layui-form{padding-left: 10px !important;}
    .tree-line .layui-form-checkbox{margin:0 10px !important;vertical-align:middle;}
    .ns-form {margin-top: 0;}
    .ns-item-block-hover-a {cursor: pointer;}
    .ns-input-box {position: absolute; right: 0; top: 50%; transform: translateY(-50%);}
    .layui-form-item .layui-form-checkbox[lay-skin=primary] {margin-top: 0;}
</style>
{/block}
{block name="main"}
<div class="layui-form">
    <!-- 店铺信息 -->
    <div class="layui-card ns-card-common ns-card-brief">
        <div class="layui-card-header">
            <span class="ns-card-title">店铺信息</span>
        </div>
        <div class="layui-card-body">
            <div class="layui-form-item">
                <label class="layui-form-label">店铺名称：</label>
                <div class="layui-input-inline">
                    {$shop_info.site_name}
                </div>
            </div>
            <div class="layui-form-item">
                <label class="layui-form-label">到期时间：</label>
                <div class="layui-input-inline">
                    {$shop_info.expire_time == 0 ?'永久':date("Y-m-d H:i:s",$shop_info.expire_time)}
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">店铺短信：</label>
                <div class="layui-input-inline">
                    {$shop_info.sms_num} 条
                </div>
            </div>

            <div class="layui-form-item">
                <label class="layui-form-label">店铺所有者：</label>
                <div class="layui-input-inline">
                    {$shop_info.username}
                </div>
            </div>

            <div id="promotion" class="layui-form-item">
                <label class="layui-form-label">营销应用：</label>
                <div class="layui-input-block">
                    <div class="site_list ns-item-block-parent ns-item-five">
                        {foreach $promotions as $promotion}
                        <a class="ns-item-block ns-item-block-hover-a">
                            <div class="ns-item-block-wrap">
                                <div class="ns-item-pic">
                                    <img src="{:img($promotion['icon'])}" />
                                </div>
                                <div class="ns-item-con">
                                    <div class="ns-item-content-title">{$promotion['title']}</div>
                                    <p class="ns-item-content-desc">{$promotion['description']}</p>
                                </div>
                            </div>
                        </a>
                        {/foreach}
                    </div>
                </div>
            </div>
			<!-- <input type="hidden" value="$shop_info.site_id" name="site_id" id="site_id" /> -->
			<div class="ns-form-row">
				<!-- <button class="layui-btn ns-bg-color" lay-submit lay-filter="save">保存</button> -->
				<button class="layui-btn layui-btn-primary" onclick="back()">返回</button>
			</div>
        </div>
    </div>

    <div class="layui-form-item layui-form-text" id="promotion_list">
    </div>
</div>
{/block}
{block name="script"}
<script src="ADMIN_JS/address.js"></script>
<script>
    function back() {
        location.href = ns.url("admin/shop/lists");
    }
</script>
{/block}